<template>
    <div>
        这里是Home页面
        <hr />
        count:{{ count }}
    </div>
</template>

<script setup>
import { computed } from 'vue'
import { useStore } from 'vuex'
const store = useStore()
const count = computed(() => store.state.count)

//mutation
store.commit('increment')
console.log(count.value);
</script>

<style>
    div{
        color: red;
    }
</style>